name="itheima is a brand of itcast"
count=0

#for 临时变量 in 被统计的数据
for x in name:
    if x=='a':
        count+=1
print(f"被统计的字符串中有{count}个a")